﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FuckCore.BO;
using FuckData.DAO;
using FuckData.Model;

namespace FuckData.BO
{
    public class ShareBO : BaseBO<ShareDAO, tbl_Share>
    {
        ShareDAO _ShareDAO = new ShareDAO();
        CommentBO _CommentBO = new CommentBO();
        public List<ShareModel> GetListShare()
        {
            var Result = _ShareDAO.GetListShare();
            if (Result == null)
                Result = new List<ShareModel>();
            else
            {
                foreach (var item in Result)
                {
                    item.ListComment = _CommentBO.GetListByShare(item.ID);
                }
            }
            return Result;
        }
    }
}
